package com.vehicle.bean;

import com.baomidou.mybatisplus.annotation.*;

import java.time.LocalDateTime;
import java.util.Date;
import java.io.Serializable;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * <p>
 *
 * </p>
 *
 * @author 校园车辆管理系统
 * @since 2023-05-17
 */
@Data
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="UserLog对象", description="")
public class UserLog implements Serializable {

    private static final long serialVersionUID=1L;

    @ApiModelProperty(value = "用户记录id")
    @TableId(value = "log_id", type = IdType.AUTO)
    private Integer logId;

    @ApiModelProperty(value = "记录内容（增删改的的内容）")
    private String content;

    @ApiModelProperty(value = "记录开始时间（登录时间或者搜索时间）")
    @TableField(fill = FieldFill.INSERT)
    private LocalDateTime createTime;

    @ApiModelProperty(value = "记录的ip地址（用户登录时需要填入的地址）")
    private String ipAddress;

    @ApiModelProperty(value = "操作的普通用户id")
    private Integer userId;

    @ApiModelProperty(value = "记录删除（0为未删除，1为已删除）")
    @TableLogic
    private Integer deleted;

    @ApiModelProperty(value = "操作类型：登录，增删改")
    private String type;

    @ApiModelProperty(value = "操作是否成功：成功，失败")
    private String success;

    @ApiModelProperty(value = "操作的管理员用户id")
    private Integer adminId;


}
